Migrate from Jackson 2.x to Jackson 3.1.4#2549
Draft
phillip-kruger wants to merge 2 commits into
Draft
Conversation
Aligns with Quarkus 4 which targets Jackson 3.x (tools.jackson:jackson-bom:3.1.4). Key changes: - Maven groupId: com.fasterxml.jackson -> tools.jackson (except annotations) - Java packages: com.fasterxml.jackson.databind/core -> tools.jackson.databind/core - JsonSerializer/JsonDeserializer -> ValueSerializer/ValueDeserializer - JsonProcessingException -> JacksonException (now unchecked) - ObjectMapper is now immutable: use JsonMapper.builder() pattern - jackson-datatype-jdk8 and jackson-datatype-jsr310 removed (built into databind) - AnnotationIntrospector API updated for Jackson 3 signatures
geoand
reviewed
Jul 2, 2026
geoand
left a comment
Contributor
There was a problem hiding this comment.
Great to see you didn't encounter any behavioral changed!
Contributor
|
Are the test failures expected? |
Member
Author
|
@geoand the failure is in our client where we use vertx even the latest Vert.x (5.1.3) still uses Jackson 2.x |
Contributor
|
In my WIP branch, I dealt with something similar in Quarkus |
Member
Author
|
@geoand ok thanks I'll go see what you have done there. What is the plan - is vert.x going to update ? Do you know ? |
Contributor
|
Vert.x supports both. Essentially what happens is that Jackson 2 is the default for Java 17 and Jackson 3 is the default for Java 21 (which Quarkus 4 will use) |
Jackson 3 enforces FAIL_ON_TRAILING_TOKENS by default, unlike Jackson 2 which silently ignored trailing content after the root JSON value. Several test JSON strings had an extra trailing } brace that was previously masked by Jackson 2's lenient parsing.
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment
Add this suggestion to a batch that can be applied as a single commit.This suggestion is invalid because no changes were made to the code.Suggestions cannot be applied while the pull request is closed.Suggestions cannot be applied while viewing a subset of changes.Only one suggestion per line can be applied in a batch.Add this suggestion to a batch that can be applied as a single commit.Applying suggestions on deleted lines is not supported.You must change the existing code in this line in order to create a valid suggestion.Outdated suggestions cannot be applied.This suggestion has been applied or marked resolved.Suggestions cannot be applied from pending reviews.Suggestions cannot be applied on multi-line comments.Suggestions cannot be applied while the pull request is queued to merge.Suggestion cannot be applied right now. Please check back later.
Aligns SmallRye GraphQL with Jackson 3.x in preparation for Quarkus 4, which targets
tools.jackson:jackson-bom:3.1.4(see geoand/quarkus jackson3 branch).This is a mechanical migration with no behavioral changes:
com.fasterxml.jackson→tools.jackson(exceptjackson-annotationswhich stays on 2.x by design)com.fasterxml.jackson.databind/core→tools.jackson.databind/coreJsonSerializer→ValueSerializer,JsonDeserializer→ValueDeserializer,SerializerProvider→SerializationContext,JsonProcessingException→JacksonException(now unchecked)JsonMapper.builder()patternjackson-datatype-jdk8andjackson-datatype-jsr310dependencies (merged intojackson-databindin 3.x)jackson-jsonb-compatmodule for Jackson 3 method signaturesValidated locally against the MicroProfile GraphQL TCK (387 tests, 0 failures).